package jtk.project4.fleet.field;
//Author : Supri Santoso
//Date created : 6 April 2011
//Date modify :   6 April 2011
//version : 1.1

import java.awt.FlowLayout;

import nl.coderight.jazz.form.FormLayout;
import nl.coderight.jazz.form.control.GroupControl;
import nl.coderight.jazz.form.control.RadioControl;
import nl.coderight.jazz.form.field.button.RadioButton;

public class AutoGeneratePOField extends GroupControl{
	private RadioControl<String> radioControl ;
	private RadioButton radioButton1 ;
	private RadioButton radioButton2 ;
	private RadioButton radioButton3 ;
	
	public  AutoGeneratePOField(String bindID){
		setTitle ("GenerateOptions.field");
		setBindID(bindID);
		createFields();
		createLayout() ;
		setLayout(new FlowLayout(FlowLayout.LEFT));
			
	}
	private void createFields(){
		radioControl = new RadioControl<String>("radio control");
		radioButton1 = new RadioButton("ManualPO");
		radioButton2 = new RadioButton("AutomaticPO-WorkOrderBased");
		radioButton3 = new RadioButton("AutomaticPO-ReorderBased");
		radioControl.addRadioButton(radioButton1, "radio1");
		radioControl.addRadioButton(radioButton2, "radio2");
		radioControl.addRadioButton(radioButton3, "radio3");
		
		//System.out.println(radioControl.getValue());
		
		}
	private void createLayout(){
		setLayout (new FormLayout())
		
		//.addLabel("label.teksArea")   
		.addRow()
		.addField(radioControl);
		
	}
}
